#!/bin/bash
#
# This script serves following purpose:
#
# 1. In BOM/Component model, it calls component makefile 
#    for those components, where component directory exists.
#
#    There are two possible outcomes based on workspace content:
#    a) If the workspace is hndcvs checkout, then version files
#       are already generated, so no updates are done.
#    b) If the workspace is sparse checkout, then version files
#       are generated by consulting automerger contents log.
#       If a component prefers to checkin a static version of
#       <component>_version.h, then no change is done to it.
#
# Copyright 2005, Broadcom, Inc.
#
# $Id: Makefile,v 13.11 2011-02-09 21:01:04 Exp $
#

SRCBASE := ..

TARGETS := epivers.h

all release: epivers compvers

# Generate epivers.h for native branch version
epivers:
	bash epivers.sh

# Generate epivers.h for native branch version
compvers:
	@if [ -s "compvers.sh" ]; then \
		echo "bash compvers.sh"; \
		bash compvers.sh; \
	else \
		echo "Skipping component version generation"; \
	fi

clean:
	rm -f $(TARGETS) *.prev

.PHONY: all release clean epivers compvers
